package com.thinkgem.jeesite.modules.devmng.web;

import com.thinkgem.jeesite.common.annotation.MobileApi;
import com.thinkgem.jeesite.common.web.BaseMessage;
import com.thinkgem.jeesite.common.web.BaseMobileApiController;
import com.thinkgem.jeesite.modules.devmng.service.TaskExecRecordService;
import com.thinkgem.jeesite.modules.devmng.vo.TaskExecRecordSubmitVo;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.http.HttpStatus;
import org.springframework.web.bind.annotation.*;

/**
 * Created by admin on 2017-12-8.
 */
@MobileApi
@RestController
@RequestMapping("/mobile-api/taskExecRecord")
public class TaskExecRecordMobileController extends BaseMobileApiController {

    @Autowired
    private TaskExecRecordService taskExecRecordService;

    @ResponseStatus(value = HttpStatus.OK)
    @RequestMapping(value = "/submit", method = RequestMethod.POST)
    public BaseMessage submit(@RequestBody TaskExecRecordSubmitVo taskExecRecordSubmitVo) {
        taskExecRecordService.submit(taskExecRecordSubmitVo);
        return BaseMessage.getDefaultSuccessMessage();
    }


}
